<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2019/5/22
  Time: 15:15
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE HTML>
<head>
    <title>Preview</title>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link href="../css/style.css" rel="stylesheet" type="text/css" media="all"/>
    <script type="text/javascript" src="../js/jquery-1.9.0.min.js"></script>
    <script type="text/javascript" src="../js/move-top.js"></script>
    <script type="text/javascript" src="../js/easing.js"></script>
    <link rel="stylesheet" type="text/css"
          href="http://apps.bdimg.com/libs/bootstrap/3.3.4/css/bootstrap.css">
</head>
<body>
<div class="header">

    <!--头部首页①-->
    <jsp:include page="headerOne.jsp" flush="true"></jsp:include>
    <div class="wrap">
        <!--头部首页②-->
        <jsp:include page="headerTwo.jsp"></jsp:include>
</div>
<div class="main">
    <div class="wrap">
        <div class="content_top">
            <div class="back-links">
                <h5><a href="/home">PE影城</a> &gt;&gt;&gt;&gt; <a href="#" class="active">${movie.mname}</a></h5>
            </div>
            <div class="clear"></div>
        </div>
        <div class="section group">
            <div class="cont-desc span_1_of_2">
                <div class="product-details">
                    <div class="grid images_3_of_2">
                        <img src="${movie.mpicture}" alt=""/>
                    </div>
                    <div class="desc span_3_of_2">
                        <h2>${movie.mname} </h2>
                        <p>${movie.mdirector}</p>
                        <p>${movie.mactor}</p>
                        <p>${movie.mtype}</p>
                        <p>${movie.mcountry}</p>
                        <p>${movie.mlanguage}</p>
                        <p>${movie.mplaytime}</p>

                    </div>
                    <div class="clear"></div>
                </div>
                <div class="product_desc">
                    <section class="about-2 section bg-gray" id="about">
                        <div class="container">
                            <div class="row">
                                <div class="col-12 col-md-5">
                                    <h2>日期</h2>
                                    <!-- 时间 -->
                                    <div style="float: left">
                                        <a

                                           style="display: inline-block; width: 150px; height: 30px; color: #fff; background-color: #f03d37; font-size: 14px; line-height: 30px; border-radius: 100px; text-align: center; -webkit-box-shadow: 0 2px 10px -2px #f03d37; box-shadow: 0 2px 10px -2px #f03d37;">${date.today}(今天)</a>
                                    </div>
                                    <script>
                                        $('#today').on('click', function () {
                                            $.ajax({
                                                type: "get",
                                                url: "/showByDate",
                                                data: {
                                                    "mid":${movie.mid},
                                                    "playDate": "${date.today}"
                                                },

                                                success: function (data) {
                                                    var cinemalist = data;
                                                    $("#cinemalist tr:gt(0)").remove();
                                                    for (i in cinemalist) {
                                                        var addRow = "<tr align=middle>\n" +
                                                            "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].cname + "</td>\n" +
                                                            "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].mstartime + "</td>\n" +
                                                            "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].mprice + "</td>\n" +
                                                            "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 ><a\n" +
                                                            "    href=\"/seat/" + cinemalist[i].cid + " \" / > 购票 </td >"      +
                                                        "\n" +
                                                        "                                            </tr>";
                                                        $("#cinemalist").append(addRow);
                                                    }


                                                }
                                            })
                                        })
                                    </script>
                                    <div style="float: left">
                                        <a
                                                style="display: inline-block; width: 150px; height: 30px; color: #fff; background-color: #f03d37; font-size: 14px; line-height: 30px; border-radius: 100px; text-align: center; -webkit-box-shadow: 0 2px 10px -2px #f03d37; box-shadow: 0 2px 10px -2px #f03d37;"
                                                id="tomorrow">${date.tomorrow}(明天)</a>
                                        <script>
                                            $('#tomorrow').on('click', function () {
                                                $.ajax({
                                                    type: "get",
                                                    url: "/showByDate",
                                                    data: {
                                                        "mid":${movie.mid},
                                                        "playDate": "${date.tomorrow}"
                                                    },

                                                    success: function (data) {
                                                        var cinemalist = data;
                                                        $("#cinemalist tr:gt(0)").remove();
                                                        for (i in cinemalist) {
                                                            var addRow = "<tr align=middle>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].cname + "</td>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].mstartime + "</td>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].mprice + "</td>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 ><a\n" +
                                                                "    href=\"/seat/" + cinemalist[i].cid + " \" / >购票</td >"      +
                                                                "\n" +
                                                                "                                            </tr>";
                                                            $("#cinemalist").append(addRow);

                                                        }


                                                    }
                                                })
                                            })
                                        </script>
                                    </div>
                                    <div>
                                        <a
                                                style="display: inline-block; width: 150px; height: 30px; color: #fff; background-color: #f03d37; font-size: 14px; line-height: 30px; border-radius: 100px; text-align: center; -webkit-box-shadow: 0 2px 10px -2px #f03d37; box-shadow: 0 2px 10px -2px #f03d37;"
                                                id="afterTomorrow">${date.afterTomorrow}(后天)</a>
                                        <script>

                                            $('#afterTomorrow').on('click', function () {
                                                $.ajax({
                                                    type: "get",
                                                    url: "/showByDate",
                                                    data: {
                                                        "mid":${movie.mid},
                                                        "playDate": "${date.afterTomorrow}"
                                                    },

                                                    success: function (data) {
                                                        var cinemalist = data;
                                                        $("#cinemalist tr:gt(0)").remove();
                                                        for (i in cinemalist) {
                                                            var addRow = "<tr align=middle>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].cname + "</td>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].mstartime + "</td>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 >" + cinemalist[i].mprice + "</td>\n" +
                                                                "                                                <td style=\"text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none\" height=40 ><a\n" +
                                                                "    href=\"/seat/" + cinemalist[i].cid + " \" / >购票</td >"      +
                                                                "\n" +
                                                                "                                            </tr>";
                                                            $("#cinemalist").append(addRow);
                                                        }


                                                    }
                                                })
                                            })
                                        </script>
                                    </div>
                                    <!-- end时间 -->
                                </div>


                            </div>
                            <!-- End row -->
                            <div class="row">
                                <div class="col-12 col-md-5">
                                    <h2>影院列表</h2>
                                    <table style="text-align: left; BORDER-LEFT-WIDTH: 0px; BORDER-COLLAPSE: collapse; BORDER-RIGHT-WIDTH: 0px"
                                           borderColor=#ff6600 bgColor=#DFFFDF cellSpacing=0 cellPadding=0 width=880px
                                           border=1 id="cinemalist">
                                        <tr align=middle>
                                            <td style="text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none "
                                                height=40>影院
                                            </td>
                                            <td style="text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none"
                                                height=40>开始时间
                                            </td>
                                            <td style="text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none"
                                                height=40>价格
                                            </td>
                                            <td style="text-align: left; BORDER-RIGHT: medium none; BORDER-LEFT: medium none"
                                                height=40>选座购票
                                            </td>
                                        </tr>


                                    </table>

                                </div>


                            </div>
                            <!-- End row -->
                        </div>
                        <!-- End container -->

                    </section>
                </div>
            </div>
            <div class="rightsidebar span_3_of_1 sidebar">
                <h2>排行榜</h2>
                <c:forEach items="${hotMovies}" var="movie" begin="0" end="4">
                    <div class="special_movies">
                        <div class="movie_poster">
                            <a href="/buy/${movie.mid}"><img src="${movie.mpicture}" alt=""/></a>
                        </div>
                        <div class="movie_desc">
                            <h4><a href="/buy/${movie.mid}">${movie.mname}</a></h4>
                            <p>${movie.mgrade}</p>
                            <span><a href="/buy/${movie.mid}">购票</a></span>
                        </div>
                        <div class="clear"></div>
                    </div>
                </c:forEach>
            </div>
        </div>
    </div>
</div>
<div class="footer">
    <div class="wrap">
        <div class="section group">

        </div>
        <div class="copy_right">
            <p>Copyright &copy; 2019.Company pigEye All rights reserved.</p>
        </div>
    </div>
</div>
<script type="text/javascript">
    $(document).ready(function () {
        $().UItoTop({easingType: 'easeOutQuart'});

    });
</script>
<a href="#" id="toTop"><span id="toTopHover"> </span></a>
<div style="display:none">
    <script src='http://v7.cnzz.com/stat.php?id=155540&web_id=155540' language='JavaScript' charset='gb2312'></script>
</div>
</body>
</html>


